import request from "@/utils/request";
import { ParseData } from "@/utils/utils";

//联合体列表分页
export const GetConsortiumList = (data: any) => {
  return request({
    method: "GET",
    url: `/lianheti?${ParseData(data)}`,
  });
};
// 联合体备注
export const NoteConsortium = (data: any) => {
  return request({
    method: "PUT",
    url: `/lianheti/beizhu`,
    data,
  });
};
// 联合体审核
export const ReviewConsortium = (data: any) => {
  return request({
    method: "PUT",
    url: `/lianheti/shenhe`,
    data,
  });
};
// 联合体编辑信息
export const GetConsortium = (data: any) => {
  return request({
    method: "GET",
    url: `/lianheti/${data.id}`,
  });
};
// 联合体详情信息
export const GetConsortiumDetail = (data: any) => {
  return request({
    method: "GET",
    url: `/lianheti/xiangqing/${data.id}`,
  });
};
// 联合体详情-参与公司信息
export const GetConsortiumDetailCompanies = (data: any) => {
  return request({
    method: "GET",
    url: `lianheti/xiangqing/canyugongsi?lhtNo=${data.lhtNo}`,
  });
};
// 联合体详情-删除参与公司
export const DeleteGetConsortiumCompany = (data: any) => {
  return request({
    method: "DELETE",
    url: `lianheti/xiangqing/canyugongsi/${data.id}`,
  });
};
// 联合体详情-添加参与公司
export const AddGetConsortiumCompany = (data: any) => {
  return request({
    method: "POST",
    url: `lianheti/xiangqing/canyugongsi`,
    data
  });
};
// 联合体新增
export const AddConsortium = (data: any) => {
  return request({
    method: "POST",
    url: `/lianheti`,
    data,
  });
};
// 联合体编辑
export const EditConsortium = (data: any) => {
  return request({
    method: "PUT",
    url: `/lianheti`,
    data,
  });
};

